import 'package:covid_19_tracker_in_flutter/ui/helper/app_colors.dart';
import 'package:covid_19_tracker_in_flutter/ui/helper/app_strings.dart';
import 'package:covid_19_tracker_in_flutter/ui/widgets/sempton_container.dart';
import 'package:flutter/material.dart';
import 'package:google_fonts/google_fonts.dart';

class SemptonScreen extends StatefulWidget {
  @override
  _SemptonScreenState createState() => _SemptonScreenState();
}

class _SemptonScreenState extends State<SemptonScreen> {
  @override
  Widget build(BuildContext context) {
    return SingleChildScrollView(
      child: Padding(
        padding: const EdgeInsets.fromLTRB(24, 30, 24, 0),
        child: Row(
          mainAxisAlignment: MainAxisAlignment.spaceEvenly,
          crossAxisAlignment: CrossAxisAlignment.start,
          children: <Widget>[
            Column(
              mainAxisAlignment: MainAxisAlignment.spaceEvenly,
              crossAxisAlignment: CrossAxisAlignment.center,  
              children: <Widget>[
                _header(AppStrings.semptonlar),
                SemptonContainer(header: AppStrings.semptom1, animationPath: AppStrings.animationTemperatureMeter),
                SemptonContainer(header: AppStrings.semptom2, animationPath: AppStrings.animationSneezing),
                SemptonContainer(header: AppStrings.semptom3, animationPath: AppStrings.animationHardSneezing),
              ],
            ),
            Column(
              children: <Widget>[
                _header(AppStrings.tavsiyeler),
                SemptonContainer(header: AppStrings.tavsiye1, animationPath: AppStrings.animationWashHands),
                SemptonContainer(header: AppStrings.tavsiye2, animationPath: AppStrings.animationDezenfekt),
                SemptonContainer(header: AppStrings.tavsiye3, animationPath: AppStrings.animationSocialDistancing),
                SemptonContainer(header: AppStrings.tavsiye4, animationPath: AppStrings.animationMask),
              ],
            ),
          ],
        ),
      ),
    );
  }

  Widget _header(String header) => Text(header, style: _headerStyle);

  TextStyle get _headerStyle => GoogleFonts.openSans(color: AppColors.colorDarkRed, fontWeight: FontWeight.bold, letterSpacing: 0.68, fontSize: 18);
}
